package b1_BST;
/**
 * 测试BST树
 */
public class TestBST {
    public static void main(String[] args) {
        //构造二叉树
        int[] data = {28,16,30,13,22,29,42};

        BST bst = new BST();
        for(int i : data){
            bst.add(i);
        }

        System.out.println(bst.toString());

        bst.remove(22);
        System.out.println(bst.toString());

        bst.add(24);
        System.out.println(bst.toString());
    }
}
